﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;

using Bricks.Component.Utils;
using Bricks.Site.Models;
using Bricks.Business.Models.ScheduleManagement;


namespace Bricks.Business.Service
{
    public interface IMonthPlanService
    {
        IQueryable<MonthPlan> MonthPlans { get; }

        #region 主界面加载
        List<MonthPlanView> GetMonthPlanList(Guid projectID, string contractType, Guid contractID);

        List<MonthPlanDetailsView> GetMonthPlanDetailList(Guid projectID, string contractType, Guid contractID, string year, string month, Guid monthPlanID);

        List<MonthPlanView> GetMonthPlanListForPreview(Guid projectID, string contractType, List<Guid> lstContractID);

        List<MonthPlanDetailsView> GetMonthPlanDetailListForPreview(Guid projectID, string contractType, List<Guid> lstContractID, string year, string month);
        #endregion

        #region 单据操作
        MonthPlanView GetMonthPlanByID(Guid id);

        List<MonthPlanDetailsView> GetMonthPlanDetailListForFlow(Guid projectID, string contractType, Guid contractID, string year, string month, Guid monthPlanID);

        void SaveMonthPlan(MonthPlanView monthPlanView, List<MonthPlanDetailsView> saveList, bool isUpdateDetails = true);

        OperationResult Delete(Guid id);
        #endregion

        #region 统计分析
        List<StatisticalAnalysisView> GetStatisticalAnalysisList(Guid projectID, string contractType, string year, List<string> lstMonth, List<Guid> lstContractID);

        List<StatisticalAnalysisDetailsView> GetStatisticalAnalysisDetailList(Guid projectID, string contractType, string year, List<string> lstMonth, Guid contractID);
        #endregion

        #region   拨付款 支表二 图表部分里面的月度数据
        List<PointView> GetMonthPlanComplete(Guid projectID, Guid contractID, double totalReviseMoney,string year,string month);
        #endregion

        #region 进度查询
        List<PointView> GetMonthPlanCompleteForMulContract(Guid projectID, string contractType, List<Guid> lstContractID, decimal totalReviseMoney);
        #endregion
    }
}